package com.res.share.mapper;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.res.share.model.ResCollection;
import com.res.share.model.ResDown;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

/**
 * <p>
 * 下载 Mapper 接口
 * </p>
 *
 * @author astupidcoder
 * @since 2021-09-21
 */
@Mapper
public interface ResDownMapper extends BaseMapper<ResDown> {

    IPage<ResDown> findResDownList(@Param("page") Page<ResDown> page, @Param("userId") Integer userId);

    void updateResDownNum(@Param("userId")  Integer userId, @Param("articleId")  Integer articleId);

    Integer findResDownNums(@Param("articleId")  Integer articleId);
}
